package org.example.model.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.util.Date;

@Data
public class Strategy {
    private Integer id;

    private Integer pid;

    private Integer total;

   @JsonFormat(pattern = "yyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date startTime;

    @JsonFormat(pattern = "yyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date endTime;

    // 感觉没什么用，可以用来人工设置该秒杀策略失效
    private Byte isActive;

    // 该属性值需要通过表连接来获取
    private String productName;

    // 根据startTime、endTime来判断当前秒杀策略是否有效
    private Integer canKill;
}